﻿Imports tiendaRegalos
Public Class WebForm1
    Inherits System.Web.UI.Page

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

    End Sub

    Protected Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click
        Try
            Dim negocio = New PedidoNegocio
            negocio.inserPedido(Me.txtIdusuario.Text, Me.txtFecha.Text, Me.txtEstado.Text, Me.txtPrecio.Text)

            Me.txtIdusuario.Text = ""
            Me.txtFecha.Text = ""
            Me.txtEstado.Text = ""
            Me.txtPrecio.Text = ""


            Response.Write("Se insertó correctamente")

        Catch ex As Exception
            Response.Write("Problemas al insertar")
        End Try
    End Sub
End Class